import React from "react"
import { Route, Switch } from "react-router-dom"

import Home from "../containers/Home"
import LifeService from "../containers/LifeService"
import Mine from "../containers/Mine"
import Shop from "../containers/Shop"
import City from "../containers/Shop/City"
import NotFound from "../containers/NotFound"
import Search from "../containers/Shop/Search"


import Community from "../containers/Home/Community"
import Roommate from "../containers/Home/Roommate"
import Locate from "../containers/Home/Locate"
import Message from "../containers/Home/Message"
import HotSearch from "../containers/Home/HotSearch"
import CurrentPage from "../containers/Home/CurrentPage"
import HouseDetail from "../containers/Home/HouseDetail"
import LocateTwo from "../containers/Home/LocateTwo"

// 生活服务
import LifeTypeOne from '../containers/LifeService/LifePage/LifeTypeOne'
import LifeTypeTwo from '../containers/LifeService/LifePage/LifeTypeTwo'
import LifePayMore from '../containers/LifeService/LifePage/LifePayMore'
import LifeWay from '../containers/LifeService/LifePage/LifeWay'
import AcarusKilling from '../containers/LifeService/LifePage/AcarusKilling'
import DailyCleaning from '../containers/LifeService/LifePage/DailyCleaning'
import RechargeableCard from '../containers/LifeService/LifePage/RechargeableCard'


export default class SubRouter extends React.Component {
  render() {
    return (
      <Switch>
        <Route exact path="/" component={ Home }></Route>
        <Route path="/life" component={ LifeService }></Route>
        <Route path="/mine" component={ Mine }></Route>

        <Route path="/shop" component={ Shop }></Route>
        <Route path="/city" component={ City }></Route>
        <Route path="/search/:keywords" component={ Search }></Route>

        {/*生活服务开始*/}
        <Route path="/lifeTypeOne/:lifeType" component={ LifeTypeOne }></Route>
        <Route path="/lifeTypeTwo/:lifeType" component={ LifeTypeTwo }></Route>
        <Route path="/lifePayMore" component={ LifePayMore }></Route>
        <Route path="/lifeWay/:lifeType" component={ LifeWay }></Route>
        <Route path="/acarus" component={ AcarusKilling }></Route>
        <Route path="/daily" component={ DailyCleaning }></Route>
        <Route path="/recharge" component={ RechargeableCard }></Route>
        {/*生活服务结束*/}
        
        {/* <Route path="/shop" component={ Shop }></Route> */}
        <Route path="/community" component={ Community }></Route>
        <Route path="/roommate" component={ Roommate }></Route>
        <Route path="/locate" component={ Locate }></Route>
        <Route path="/message" component={ Message }></Route>
        <Route path="/hotsearch" component={ HotSearch }></Route>
        <Route path="/currentpage/:region" component={ CurrentPage }></Route>
        <Route path="/housedetail/:id" component={ HouseDetail }></Route>
        <Route path="/locatetwo" component={ LocateTwo }></Route>


        <Route component={ NotFound }></Route>
      </Switch>
    )
  }
}
